<template>
  <view class="log-list">
    <view 
      class="log-item" 
      v-for="item in logData" 
      :key="item.id"
    >
      <view class="circle"></view>
      <view class="log-info">
        <text class="time">{{item.createTime}}</text>
        <text class="detail">{{item.content}}</text>
      </view>
    </view>
  </view>
</template>

<script>
	import http from '../../http';
export default {
  data() {
    return {
      logData: []
    };
  },
  methods:{
	  getList() {
	  	http({
	  		url: "/api/student/user/log",
	  		method: "post",
	  	}).then(res => {
	  		console.log(res,"log");
	  		if (res.code === 1) {
	  			this.logData = res.response
	  		}
	  	})
	  },
  },
  onLoad() {
  	this.getList()
  }
};
</script>

<style scoped>
.log-list {
  padding: 15rpx;
}
.log-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 20rpx;
}
.circle {
  width: 20rpx;
  height: 20rpx;
  border-radius: 50%;
  border: 2px solid #007aff;
  margin-right: 15rpx;
  margin-top: 5rpx;
}
.log-info {
  display: flex;
  flex-direction: column;
}
.time {
  font-size: 26rpx;
  color: #999;
  margin-bottom: 5rpx;
}
.detail {
  font-size: 28rpx;
  color: #333;
}
</style>
